package com.example.demo.pojo;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.ToString;
import org.springframework.stereotype.Component;

import java.io.Serializable;
import java.time.LocalDateTime;

// 明细类
@Data
@NoArgsConstructor
@ToString
@EqualsAndHashCode
public class Minute implements Serializable {

    // 钱包明细主键id
    @TableId(type = IdType.AUTO)
    private Integer id;

    // 明细关联钱包
    private Integer wallet_id;

    // 变动金额
    private Double amount;

    // 此刻余额
    private Double balance_at;

    // 变动类型，1代表消费，2代表退款
    private String type;

    // 变动时间
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime created_time;
}


